Implementing close prevention with changes. Not quite working. Save button triggered without being clicked.
Edit Product:
ID
Name
Unit Price
Save
You have changes pending that will be discarded on exit. Do you still wish to exit?
DISCARD AND EXIT
CANCEL